package routers

import (
	"5title_gin/internal/api/middleware"
	v1 "5title_gin/internal/api/v1"
	"5title_gin/internal/model/system"
	"github.com/gin-gonic/gin"
)

func SystemRouter(g *gin.RouterGroup) {
	app := v1.App.SystemApi
	// 部门管理
	g.POST("dept/create",
		middleware.BindJsonMiddleware[system.SysDept],
		app.CreateDept)
	g.GET("dept/list",
		app.GetDeptList)
	g.GET("dept/getDeptOptions", app.GetDeptOptions)
	/** 图片上传 */
	g.POST("images/upload", app.UploadView)
}
